<?php
namespace app\home\controller;
use think\Db;
use think\Request;
class Curriculum extends Index{
    /**
     *课程列表
    */
    public function cuLumList(){
        if(Request::instance()->get()){
            $param = Request::instance()->get();
            $name = trim($param['name']);
            $row = Db::table('courses')->where("courses_del = 0 and courses_name Like '%$name%'")->select();
            $this->view->assign('row',$row);
            $this->view->assign('name',$name);
            return view();
        }else{
            $name ="搜索";
            $row = Db::table('courses')->where('courses_del = 0')->select();
            $this->view->assign('row',$row);
            $this->view->assign('name',$name);
            return view();
        }


    }








}